<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <script>
        console.log("888")
        const rule = {
            name: 'String',
            age: 'Number',
            sex: 'String',
            Son: {
                aa: 'Boolean',
                bb: 'Array',
                cc: 'String',
            },
            Son1: {
                dd: 'Number',
                ee: 'Null',
                ff: 'String',
                gg: {
                    hh: 'Number',
                    ii: 'String',
                    jj: {
                        kk: 'Number',
                        ll: 'Boolean',
                    }
                },
                mm: {
                    nn: 'String',
                    pp: 'Boolean',
                    oo: 'number',
                }
            }
        }
        const num = {
            name: 'aa',
            age: 'bb',
            sex: 19,
            Son: {
                aa: 'gg',
                bb: 'asd',
                cc: false,
            },
            Son1: {
                dd: 90,
                ee: 34,
                ff: 'ii',
                gg: {
                    hh: 89,
                    ii: 45,
                    jj: {
                        kk: 'tt',
                        ll: false,
                    }
                },
                mm: {
                    nn: 19,
                    pp: true,
                    oo: 10,
                }
            }
        }
    //[age,sex,Son.aa,Son.bb,Son.cc,Son1.ee,Son1.gg.ii,Son1.gg.jj.kk,Son1.mm.nn]
    // 根据rule验证num   输出最后那个数组
    
    </script>
</body>

</html>